import { useState, useCallback } from 'react';

export interface User {
  adminId: number;
  adminName: string;
  areaId: number;
  areaName: string;
  authRole: number;
  authRoleName: string;
  mapUrl: string;
  token: string;
}

export default function useAuthModel() {
  // const [user] = useState<User>(
  //   JSON.parse(localStorage.getItem('adminInfo') || ''),
  // );

  const signin = useCallback((account, password) => {
    // signin implementation
    // setUser(user from signin API)
  }, []);

  const signout = useCallback(() => {
    // signout implementation
    // setUser(null)
  }, []);

  return {
    // user,
    signin,
    signout,
  };
}
